(function(){
    function Lab() {
        var device = new Object();
        
        device = function(name){
            this.name = name;
            this.switchOn = false;
        };
        
        var dev1 = new device('dev1');
        console.log(dev1);

        var dev2 = new device('dev2');
        console.log(dev2);

        var dev3 = new device('dev3');
        console.log(dev3);

        var dev5 = new device('dev5');
        console.log(dev5);

        var dev6 = new device('dev6');
        console.log(dev6);
        
        this.init = function() {
            
            
            
        };
            
    }
    
    if (!window.lab) window.lab = new Lab();
    window.onload = function() {
        window.lab.init();
    };
})();